package mijia

import (af "learning/gooop/creational_patterns/abstract_factory")

func init() {
	af.DefaultFactoryRegistry.Set("mijia", newMijiaFactory())
}

type tMijiaFactory struct {
}

func newMijiaFactory() af.ISmartFactory {
	return &tMijiaFactory{}
}

func (me *tMijiaFactory) CreateLight(info *af.DeviceInfo) (error, af.ILight) {
	return nil, newMijiaLight(info)
}

func (me *tMijiaFactory) CreateAirConditioner(info *af.DeviceInfo) (error, af.IAirConditioner) {
	return nil, newMijiaAirConditioner(info)
}
